﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/ConvergenceTheme.Master" Inherits="System.Web.Mvc.ViewPage<elfam.web.ViewModels.MyOrdersViewModel>" %>
<%@ Import Namespace="elfam.web.Extensions" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	Мои заказы
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

    <h2>Мои заказы</h2>
    <table class="box-table-a">
        <tr>
            <th></th>
            <th>Дата</th>
            <th>Сумма</th>
            <th>Статус</th>
        </tr>

    <% foreach (var item in Model.Orders) { %>
    
        <tr>
            <td><a href="/Order/DetailsUser/<%= item.Uid %>">смотреть</a></td>
            <td><%= item.Date.ToString("d") %></td>
            <td><%= item.SummWithDiscount().ToString("C0") %></td>
            <td><%= item.Status.Description(item.Status)%></td>
        </tr>
    
    <% } %>

    </table>

</asp:Content>
